#!/usr/bin/env python3
# -*- coding: UTF-8 -*-

import os
import sys


def main():

    sourcefile=sys.argv[1]#tse file
    targetfile=sys.argv[2]#our file

    
    if not os.path.exists(sourcefile):
        print('tse file is invalid')
        exit(1)
    if not os.path.exists(targetfile):
        print('your file is invalid')
        exit(1)

    lineset = set()

    # print('ok')
    with open(sourcefile,mode='r') as source:
        for line in source:
            #print(line)
            line=line.strip()
            lineset.add(line)
        source.close()

    with open(targetfile,mode='r') as target:
        for line in target:
            #print(line)
            line=line.strip()
            if line in lineset:
                lineset.remove(line)
        target.close()


    for k in lineset:
        print(k+"\n")
    print("not cover total:"+str(len(lineset)))

    
if __name__=='__main__':
    main()
    
